#include <vector>
#include <stdio.h>
using namespace std;


class a{
    public:
    void print(){
        printf("a instance.\n");
    }
};


int main(int argc, char const *argv[])
{
    a demo = a();
    vector<a*> list = vector<a*>();
    list.push_back(&demo);
    for(auto item = list.begin(), end = list.end(); item != end; item++) {
        (*item)->print();        
    }

    return 0;
}
